package com.wsk.bean;


import javax.persistence.*;

@Entity(name="userintegral")
public class UserIntegral {
	@Id
	private Integer id;
	
	@OneToOne
	@PrimaryKeyJoinColumn
	private UserInformation userInformation;
	
	@Column(columnDefinition="int default 0",nullable=false)
	private int integral;
	
//	@OneToMany(mappedBy="userintegral")
//	private List<IntegralSource> integralSource;

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public UserInformation getUserInformation() {
		return userInformation;
	}

	public void setUserInformation(UserInformation userInformation) {
		this.userInformation = userInformation;
	}

	public int getIntegral() {
		return integral;
	}

	public void setIntegral(int integral) {
		this.integral = integral;
	}

//	public List<IntegralSource> getIntegralSource() {
//		return integralSource;
//	}
//
//	public void setIntegralSource(List<IntegralSource> integralSource) {
//		this.integralSource = integralSource;
//	}
}
